﻿using System.Threading.Tasks;

namespace Sidvall.WorkItemManager.Data
{
    public partial interface IWorkItem : Sidvall.Data.IDataRowContextProvider
    {
        global::Sidvall.WorkItemManager.Workflow.ThreadAction CanceledAction { get; set; }
        string Description { get; set; }
        byte ExecutionCompletionPercentage { get; set; }
        string ExecutionContext { get; set; }
        System.Nullable<System.DateTime> ExecutionContextUpdated { get; set; }
        int ExecutionOrder { get; set; }
        System.Nullable<System.DateTime> ExecutionStartTime { get; set; }
        global::Sidvall.WorkItemManager.Workflow.ThreadAction FailedAction { get; set; }
        int FailedExecutionCount { get; set; }
        bool ForceExecution { get; set; }
        bool IsCanceled { get; set; }
        bool IsEnabled { get; set; }
        System.Nullable<System.DateTime> LastExecutionEndTime { get; set; }
        System.Nullable<System.DateTime> LastExecutionStartTime { get; set; }
        string LastResultMessage { get; set; }
        System.Nullable<global::Sidvall.WorkItemManager.Workflow.WorkItemResultType> LastWorkItemResultId { get; set; }
        int LogDayCount { get; set; }
        global::Sidvall.WorkItemManager.Workflow.LogModes LogModeId { get; set; }
        string Name { get; set; }
        int RetryCount { get; set; }
        System.Nullable<System.DateTime> RetryTime { get; set; }
        int SensorLogDayCount { get; set; }
        long WorkerId { get; set; }
        string WorkItemContext { get; set; }
        System.Nullable<long> WorkItemId { get; set; }
        global::Sidvall.WorkItemManager.Workflow.WorkItemStatus WorkItemStatusId { get; set; }
        System.Nullable<long> WorkItemTypeId { get; set; }
        string WorkRetryPolicyContext { get; set; }
        System.Nullable<long> WorkRetryPolicyId { get; set; }
        System.Nullable<System.Int32> ServerConnectionId { get; set; }
        IWorker Worker { get; set; }
        IWorkItemType WorkItemType { get; set; }
        IWorkRetryPolicy WorkRetryPolicy { get; set; }
        System.Collections.Generic.IEnumerable<IWorkItemLog> WorkItemLogs { get; }
        void SetWorkItemLogs(Sidvall.Data.IDataRowProvider<IWorkItemLog> items);
        System.Collections.Generic.IEnumerable<IWorkItemSensor> WorkItemSensors { get; }
        void SetWorkItemSensors(Sidvall.Data.IDataRowProvider<IWorkItemSensor> items);
        System.Collections.Generic.IEnumerable<IWorkItemWorkCondition> WorkItemWorkConditions { get; }
        void SetWorkItemWorkConditions(Sidvall.Data.IDataRowProvider<IWorkItemWorkCondition> items);
    }
}